package com.sdz.chapitre16;

public enum Langage {
	JAVA ("Langage Java", "Eclipse"),
	C ("Langage C", "Code block"),
	CPlus ("Langage C+", "Visual studio"),
	PHP ("Langage PHP", "Notepad++");
	
	private String name = "";
	private String editor = "";
	
	Langage (String pNom) {
		name = pNom;
	}
	Langage (String pNom, String pEditor) {
		name = pNom;
		editor = pEditor;
	}
	
	public void getEditor() {
		System.out.println("Editeur : " + editor);
	}
	public String toString() {
		return name;
	}
	
	public static void main (String args[]) {
		Langage l1 = Langage.JAVA;
		Langage l2 = Langage.PHP;
		
		l1.getEditor();
		l2.getEditor();
		
	}
	
}
